using Google.ProtocolBuffers;
using micromsg.Proto;
using System;
using System.CodeDom.Compiler;
using System.Diagnostics;
using System.IO;
using System.Runtime.CompilerServices;
namespace micromsg
{
	[GeneratedCode("ProtoGen", "2.3.0.277"), DebuggerNonUserCode, CompilerGenerated]
	public sealed class ShakeMatchResponse : GeneratedMessageLite<ShakeMatchResponse, ShakeMatchResponse.Builder>
	{
		[GeneratedCode("ProtoGen", "2.3.0.277"), DebuggerNonUserCode, CompilerGenerated]
		public sealed class Builder : GeneratedBuilderLite<ShakeMatchResponse, ShakeMatchResponse.Builder>
		{
			private bool resultIsReadOnly;
			private ShakeMatchResponse result;
			protected override ShakeMatchResponse.Builder ThisBuilder
			{
				get
				{
					return this;
				}
			}
			public override bool IsInitialized
			{
				get
				{
					return this.result.IsInitialized;
				}
			}
			protected override ShakeMatchResponse MessageBeingBuilt
			{
				get
				{
					return this.PrepareBuilder();
				}
			}
			public override ShakeMatchResponse DefaultInstanceForType
			{
				get
				{
					return ShakeMatchResponse.DefaultInstance;
				}
			}
			public BaseResponse BaseResponse
			{
				get
				{
					return this.result.BaseResponse;
				}
				set
				{
					this.SetBaseResponse(value);
				}
			}
			public string Tips
			{
				get
				{
					return this.result.Tips;
				}
				set
				{
					this.SetTips(value);
				}
			}
			public uint Ret
			{
				get
				{
					return this.result.Ret;
				}
				set
				{
					this.SetRet(value);
				}
			}
			public Builder()
			{
				this.result = ShakeMatchResponse.DefaultInstance;
				this.resultIsReadOnly = true;
			}
			internal Builder(ShakeMatchResponse cloneFrom)
			{
				this.result = cloneFrom;
				this.resultIsReadOnly = true;
			}
			private ShakeMatchResponse PrepareBuilder()
			{
				if (this.resultIsReadOnly)
				{
					ShakeMatchResponse other = this.result;
					this.result = new ShakeMatchResponse();
					this.resultIsReadOnly = false;
					this.MergeFrom(other);
				}
				return this.result;
			}
			public override ShakeMatchResponse.Builder Clear()
			{
				this.result = ShakeMatchResponse.DefaultInstance;
				this.resultIsReadOnly = true;
				return this;
			}
			public override ShakeMatchResponse.Builder Clone()
			{
				if (this.resultIsReadOnly)
				{
					return new ShakeMatchResponse.Builder(this.result);
				}
				return new ShakeMatchResponse.Builder().MergeFrom(this.result);
			}
			public override ShakeMatchResponse BuildPartial()
			{
				if (this.resultIsReadOnly)
				{
					return this.result;
				}
				this.resultIsReadOnly = true;
				return this.result.MakeReadOnly();
			}
			public override ShakeMatchResponse.Builder MergeFrom(IMessageLite other)
			{
				if (other is ShakeMatchResponse)
				{
					return this.MergeFrom((ShakeMatchResponse)other);
				}
				base.MergeFrom(other);
				return this;
			}
			public override ShakeMatchResponse.Builder MergeFrom(ShakeMatchResponse other)
			{
				return this;
			}
			public override ShakeMatchResponse.Builder MergeFrom(ICodedInputStream input)
			{
				return this.MergeFrom(input, ExtensionRegistry.Empty);
			}
			public override ShakeMatchResponse.Builder MergeFrom(ICodedInputStream input, ExtensionRegistry extensionRegistry)
			{
				this.PrepareBuilder();
				uint num;
				string text;
				while (input.ReadTag(out num, out text))
				{
					if (num == 0u && text != null)
					{
						int num2 = Array.BinarySearch<string>(ShakeMatchResponse._shakeMatchResponseFieldNames, text, StringComparer.get_Ordinal());
						if (num2 < 0)
						{
							this.ParseUnknownField(input, extensionRegistry, num, text);
							continue;
						}
						num = ShakeMatchResponse._shakeMatchResponseFieldTags[num2];
					}
					uint num3 = num;
					if (num3 <= 10u)
					{
						if (num3 == 0u)
						{
							throw InvalidProtocolBufferException.InvalidTag();
						}
						if (num3 == 10u)
						{
							BaseResponse.Builder builder = BaseResponse.CreateBuilder();
							if (this.result.hasBaseResponse)
							{
								builder.MergeFrom(this.BaseResponse);
							}
							input.ReadMessage(builder, extensionRegistry);
							this.BaseResponse = builder.BuildPartial();
							continue;
						}
					}
					else
					{
						if (num3 == 18u)
						{
							this.result.hasTips = input.ReadString(ref this.result.tips_);
							continue;
						}
						if (num3 == 24u)
						{
							this.result.hasRet = input.ReadUInt32(ref this.result.ret_);
							continue;
						}
					}
					if (WireFormat.IsEndGroupTag(num))
					{
						return this;
					}
					this.ParseUnknownField(input, extensionRegistry, num, text);
				}
				return this;
			}
			public ShakeMatchResponse.Builder SetBaseResponse(BaseResponse value)
			{
				ThrowHelper.ThrowIfNull(value, "value");
				this.PrepareBuilder();
				this.result.hasBaseResponse = true;
				this.result.baseResponse_ = value;
				return this;
			}
			public ShakeMatchResponse.Builder SetBaseResponse(BaseResponse.Builder builderForValue)
			{
				ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
				this.PrepareBuilder();
				this.result.hasBaseResponse = true;
				this.result.baseResponse_ = builderForValue.Build();
				return this;
			}
			public ShakeMatchResponse.Builder MergeBaseResponse(BaseResponse value)
			{
				ThrowHelper.ThrowIfNull(value, "value");
				this.PrepareBuilder();
				if (this.result.hasBaseResponse && this.result.baseResponse_ != BaseResponse.DefaultInstance)
				{
					this.result.baseResponse_ = BaseResponse.CreateBuilder(this.result.baseResponse_).MergeFrom(value).BuildPartial();
				}
				else
				{
					this.result.baseResponse_ = value;
				}
				this.result.hasBaseResponse = true;
				return this;
			}
			public ShakeMatchResponse.Builder ClearBaseResponse()
			{
				this.PrepareBuilder();
				this.result.hasBaseResponse = false;
				this.result.baseResponse_ = null;
				return this;
			}
			public ShakeMatchResponse.Builder SetTips(string value)
			{
				ThrowHelper.ThrowIfNull(value, "value");
				this.PrepareBuilder();
				this.result.hasTips = true;
				this.result.tips_ = value;
				return this;
			}
			public ShakeMatchResponse.Builder ClearTips()
			{
				this.PrepareBuilder();
				this.result.hasTips = false;
				this.result.tips_ = "";
				return this;
			}
			public ShakeMatchResponse.Builder SetRet(uint value)
			{
				this.PrepareBuilder();
				this.result.hasRet = true;
				this.result.ret_ = value;
				return this;
			}
			public ShakeMatchResponse.Builder ClearRet()
			{
				this.PrepareBuilder();
				this.result.hasRet = false;
				this.result.ret_ = 0u;
				return this;
			}
		}
		public const int BaseResponseFieldNumber = 1;
		public const int TipsFieldNumber = 2;
		public const int RetFieldNumber = 3;
		private static readonly ShakeMatchResponse defaultInstance;
		private static readonly string[] _shakeMatchResponseFieldNames;
		private static readonly uint[] _shakeMatchResponseFieldTags;
		private bool hasBaseResponse;
		private BaseResponse baseResponse_;
		private bool hasTips;
		private string tips_ = "";
		private bool hasRet;
		private uint ret_;
		private int memoizedSerializedSize = -1;
		public static ShakeMatchResponse DefaultInstance
		{
			get
			{
				return ShakeMatchResponse.defaultInstance;
			}
		}
		public override ShakeMatchResponse DefaultInstanceForType
		{
			get
			{
				return ShakeMatchResponse.DefaultInstance;
			}
		}
		protected override ShakeMatchResponse ThisMessage
		{
			get
			{
				return this;
			}
		}
		public BaseResponse BaseResponse
		{
			get
			{
				return this.baseResponse_ ?? BaseResponse.DefaultInstance;
			}
		}
		public string Tips
		{
			get
			{
				return this.tips_;
			}
		}
		public uint Ret
		{
			get
			{
				return this.ret_;
			}
		}
		public override bool IsInitialized
		{
			get
			{
				return this.hasBaseResponse && this.hasRet && this.BaseResponse.IsInitialized;
			}
		}
		public override int SerializedSize
		{
			get
			{
				int num = this.memoizedSerializedSize;
				if (num != -1)
				{
					return num;
				}
				num = 0;
				if (this.hasBaseResponse)
				{
					num += CodedOutputStream.ComputeMessageSize(1, this.BaseResponse);
				}
				if (this.hasTips)
				{
					num += CodedOutputStream.ComputeStringSize(2, this.Tips);
				}
				if (this.hasRet)
				{
					num += CodedOutputStream.ComputeUInt32Size(3, this.Ret);
				}
				this.memoizedSerializedSize = num;
				return num;
			}
		}
		private ShakeMatchResponse()
		{
		}
		public override void WriteTo(ICodedOutputStream output)
		{
			int arg_06_0 = this.SerializedSize;
			string[] shakeMatchResponseFieldNames = ShakeMatchResponse._shakeMatchResponseFieldNames;
			if (this.hasBaseResponse)
			{
				output.WriteMessage(1, shakeMatchResponseFieldNames[0], this.BaseResponse);
			}
			if (this.hasTips)
			{
				output.WriteString(2, shakeMatchResponseFieldNames[2], this.Tips);
			}
			if (this.hasRet)
			{
				output.WriteUInt32(3, shakeMatchResponseFieldNames[1], this.Ret);
			}
		}
		public override int GetHashCode()
		{
			int num = base.GetType().GetHashCode();
			if (this.hasBaseResponse)
			{
				num ^= this.baseResponse_.GetHashCode();
			}
			if (this.hasTips)
			{
				num ^= this.tips_.GetHashCode();
			}
			if (this.hasRet)
			{
				num ^= this.ret_.GetHashCode();
			}
			return num;
		}
		public override bool Equals(object value)
		{
			ShakeMatchResponse shakeMatchResponse = value as ShakeMatchResponse;
			return shakeMatchResponse != null && (this.hasBaseResponse == shakeMatchResponse.hasBaseResponse && (!this.hasBaseResponse || this.baseResponse_.Equals(shakeMatchResponse.baseResponse_))) && (this.hasTips == shakeMatchResponse.hasTips && (!this.hasTips || this.tips_.Equals(shakeMatchResponse.tips_))) && (this.hasRet == shakeMatchResponse.hasRet && (!this.hasRet || this.ret_.Equals(shakeMatchResponse.ret_)));
		}
		public override void PrintTo(TextWriter writer)
		{
			GeneratedMessageLite<ShakeMatchResponse, ShakeMatchResponse.Builder>.PrintField("BaseResponse", this.hasBaseResponse, this.baseResponse_, writer);
			GeneratedMessageLite<ShakeMatchResponse, ShakeMatchResponse.Builder>.PrintField("Tips", this.hasTips, this.tips_, writer);
			GeneratedMessageLite<ShakeMatchResponse, ShakeMatchResponse.Builder>.PrintField("Ret", this.hasRet, this.ret_, writer);
		}
		public static ShakeMatchResponse ParseFrom(byte[] data)
		{
			return ShakeMatchResponse.CreateBuilder().MergeFrom(data).BuildParsed();
		}
		private ShakeMatchResponse MakeReadOnly()
		{
			return this;
		}
		public static ShakeMatchResponse.Builder CreateBuilder()
		{
			return new ShakeMatchResponse.Builder();
		}
		public override ShakeMatchResponse.Builder ToBuilder()
		{
			return ShakeMatchResponse.CreateBuilder(this);
		}
		public override ShakeMatchResponse.Builder CreateBuilderForType()
		{
			return new ShakeMatchResponse.Builder();
		}
		public static ShakeMatchResponse.Builder CreateBuilder(ShakeMatchResponse prototype)
		{
			return new ShakeMatchResponse.Builder(prototype);
		}
		static ShakeMatchResponse()
		{
			ShakeMatchResponse.defaultInstance = new ShakeMatchResponse().MakeReadOnly();
			ShakeMatchResponse._shakeMatchResponseFieldNames = new string[]
			{
				"BaseResponse",
				"Ret",
				"Tips"
			};
			ShakeMatchResponse._shakeMatchResponseFieldTags = new uint[]
			{
				10u,
				24u,
				18u
			};
			object.ReferenceEquals(micromsg.Proto.ShakeMatchResponse.Descriptor, null);
		}
	}
}
